package com.ys.entity.base;

import java.util.Date;
import javax.persistence.Table;
import com.alibaba.fastjson.annotation.JSONField;
import com.ys.annotation.YsField;
import com.ys.entity.base.BaseEntity;
/**
*/
@Table(name="TB_Platform", catalog="Id")
public class TbPlatform extends BaseEntity<TbPlatform> {

	@YsField(nameDataBase="Id", nameJava="id", typeDataBase="bigint")
	private Long id;
	@YsField(nameDataBase="Code", nameJava="code", typeDataBase="varchar")
	private String code;
	@YsField(nameDataBase="Name", nameJava="name", typeDataBase="varchar")
	private String name;
	@YsField(nameDataBase="EncryptKey", nameJava="encryptKey", typeDataBase="varchar")
	private String encryptKey;
	@YsField(nameDataBase="EncryptSecret", nameJava="encryptSecret", typeDataBase="varchar")
	private String encryptSecret;
	@YsField(nameDataBase="EncryptToken", nameJava="encryptToken", typeDataBase="varchar")
	private String encryptToken;
	@YsField(nameDataBase="AuthDate", nameJava="authDate", typeDataBase="char")
	private String authDate;
	@YsField(nameDataBase="AuthExpireDate", nameJava="authExpireDate", typeDataBase="char")
	private String authExpireDate;
	@YsField(nameDataBase="Status", nameJava="status", typeDataBase="tinyint")
	private Integer status;
	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@YsField(nameDataBase="CreateTime", nameJava="createTime", typeDataBase="datetime")
	private Date createTime;
	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@YsField(nameDataBase="UpdateTime", nameJava="updateTime", typeDataBase="datetime")
	private Date updateTime;

	public Long getId() {
		return id;
	}
	public TbPlatform setId(Long id) {
		this.id = id;
		return this;
	}
	public String getCode() {
		return code;
	}
	public TbPlatform setCode(String code) {
		this.code = code;
		return this;
	}
	public String getName() {
		return name;
	}
	public TbPlatform setName(String name) {
		this.name = name;
		return this;
	}
	public String getEncryptKey() {
		return encryptKey;
	}
	public TbPlatform setEncryptKey(String encryptKey) {
		this.encryptKey = encryptKey;
		return this;
	}
	public String getEncryptSecret() {
		return encryptSecret;
	}
	public TbPlatform setEncryptSecret(String encryptSecret) {
		this.encryptSecret = encryptSecret;
		return this;
	}
	public String getEncryptToken() {
		return encryptToken;
	}
	public TbPlatform setEncryptToken(String encryptToken) {
		this.encryptToken = encryptToken;
		return this;
	}
	public String getAuthDate() {
		return authDate;
	}
	public TbPlatform setAuthDate(String authDate) {
		this.authDate = authDate;
		return this;
	}
	public String getAuthExpireDate() {
		return authExpireDate;
	}
	public TbPlatform setAuthExpireDate(String authExpireDate) {
		this.authExpireDate = authExpireDate;
		return this;
	}
	public Integer getStatus() {
		return status;
	}
	public TbPlatform setStatus(Integer status) {
		this.status = status;
		return this;
	}
	public Date getCreateTime() {
		return createTime;
	}
	public TbPlatform setCreateTime(Date createTime) {
		this.createTime = createTime;
		return this;
	}
	public Date getUpdateTime() {
		return updateTime;
	}
	public TbPlatform setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
		return this;
	}

	public static TbPlatform tbPlatform(
		String code,
		String name,
		String encryptKey,
		String encryptSecret,
		String encryptToken,
		String authDate,
		String authExpireDate,
		Integer status
			) {
		TbPlatform entity = new TbPlatform();
		entity.setCode(code);
		entity.setName(name);
		entity.setEncryptKey(encryptKey);
		entity.setEncryptSecret(encryptSecret);
		entity.setEncryptToken(encryptToken);
		entity.setAuthDate(authDate);
		entity.setAuthExpireDate(authExpireDate);
		entity.setStatus(status);
		return entity;
	}
}